<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title></title>
<style type="text/css">
<!--
body {
	margin-left: 0px;
	margin-top: 0px;
	margin-right: 0px;
	margin-bottom: 0px;
}
.STYLE1 {font-size: 12px}
.STYLE4 {
	font-size: 12px;
	color: #1F4A65;
	font-weight: bold;
}

a:link {
	font-size: 12px;
	color: #06482a;
	text-decoration: none;

}
a:visited {
	font-size: 12px;
	color: #06482a;
	text-decoration: none;
}
a:hover {
	font-size: 12px;
	color: #FF0000;
	text-decoration: underline;
}
a:active {
	font-size: 12px;
	color: #FF0000;
	text-decoration: none;
}
.STYLE7 {font-size: 12}

-->

.black_overlay{ 
  display: none;  position: absolute;  top: 0%;  left: 0%;  width: 100%;  height: 100%;  background-color: #999;  z-index:1001;  -moz-opacity: 0.8;  opacity:.80;  filter:alpha(opacity=80);  }  

  .white_content {  display: none;
	position: absolute;
	top: 100px;
	left: 300px;
	width: 461px;
	height: auto;
	padding: 10px;
	border: 10px solid #EAFCD5;
	background-color: white;
	z-index:1002;
	overflow: auto;
	font-size: 12px;
}
</style>
<script type="text/javascript" src="${applicationScope.ROOT}/commentJS/jquery.min.js"></script>
<script type="text/javascript" src="${applicationScope.ROOT}/commentJS/comment.js"></script>
<script type="text/javascript" src="${applicationScope.ROOT}/commentJS/My97DatePicker/WdatePicker.js"></script>
<script type="text/javascript" src="${applicationScope.ROOT}/admin/activity/js/activity.js"></script>
<script>
var root="${applicationScope.ROOT}";

var  highlightcolor='#eafcd5';
//此处clickcolor只能用win系统颜色代码才能成功,如果用#xxxxxx的代码就不行,还没搞清楚为什么:(
var  clickcolor='#51b2f6';
function  changeto(){
source=event.srcElement;
if  (source.tagName=="TR"||source.tagName=="TABLE")
return;
while(source.tagName!="TD")
source=source.parentElement;
source=source.parentElement;
cs  =  source.children;
//alert(cs.length);
if  (cs[1].style.backgroundColor!=highlightcolor&&source.id!="nc"&&cs[1].style.backgroundColor!=clickcolor)
for(i=0;i<cs.length;i++){
	cs[i].style.backgroundColor=highlightcolor;
}
}

function  changeback(){
if  (event.fromElement.contains(event.toElement)||source.contains(event.toElement)||source.id=="nc")
return
if  (event.toElement!=source&&cs[1].style.backgroundColor!=clickcolor)
//source.style.backgroundColor=originalcolor
for(i=0;i<cs.length;i++){
	cs[i].style.backgroundColor="";
}
}

function  clickto(){
source=event.srcElement;
if  (source.tagName=="TR"||source.tagName=="TABLE")
return;
while(source.tagName!="TD")
source=source.parentElement;
source=source.parentElement;
cs  =  source.children;
//alert(cs.length);
if  (cs[1].style.backgroundColor!=clickcolor&&source.id!="nc")
for(i=0;i<cs.length;i++){
	cs[i].style.backgroundColor=clickcolor;
}
else
for(i=0;i<cs.length;i++){
	cs[i].style.backgroundColor="";
}
}
</script>
</head>

<body>
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td height="30"><table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td width="15" height="30"><img src="${applicationScope.ROOT}/admin/company/images/tab_03.gif" width="15" height="30" /></td>
        <td width="1101" background="${applicationScope.ROOT}/admin/company/images/tab_05.gif"><img src="${applicationScope.ROOT}/admin/company/images/311.gif" width="16" height="16" /> 
        <span class="STYLE4">
        <a href="javascript:;">活动管理</a>
        
        </span>
        </td>
        <td width="281" background="${applicationScope.ROOT}/admin/company/images/tab_05.gif"><table border="0" align="right" cellpadding="0" cellspacing="0">
            <tr>
              <td width="60"><table width="87%" border="0" cellpadding="0" cellspacing="0">
                  <tr>
                    <td class="STYLE1"><div align="center">
                        <input id="ck" type="checkbox" value="checkbox" onclick="checkedBox()" />
                    </div></td>
                    <td class="STYLE1"><div align="center" onclick="checkedBox()">全选</div></td>
                  </tr>
              </table></td>
              <td width="60">
              <table width="90%" border="0" cellpadding="0" cellspacing="0">
                  <tr>
                  <td class="STYLE1"><div align="center"><a href="javascript:;" onclick="del()"><img src="${applicationScope.ROOT}/admin/company/images/083.gif" width="14" height="14" /></a></div></td>
                    <td class="STYLE1"><div align="center"><a href="javascript:;p" onclick="del()">删除</a></div></td>
                  </tr>
              </table>
              </td>
              <td width="60"><table width="90%" border="0" cellpadding="0" cellspacing="0">
                  <tr>
                  <!--
                    <td class="STYLE1"><div align="center"><a href="${applicationScope.ROOT}/admin/company/addCompany.jsp"><img src="${applicationScope.ROOT}/admin/company/images/001.gif" width="14" height="14" /></a></div></td>
                    <td class="STYLE1"><div align="center"><a href="${applicationScope.ROOT}/admin/company/addCompany.jsp">新增</a></div></td>
                  -->
                  <td class="STYLE1"><div align="center"><a href="javascript:;" onclick="showAdd()"><img src="${applicationScope.ROOT}/admin/company/images/001.gif" width="14" height="14" /></a></div></td>
                    <td class="STYLE1"><div align="center"><a href="javascript:;" onclick="showAdd()">新增</a></div></td>
                  </tr>
              </table></td>
              <!-- 
              <td width="52"><table width="88%" border="0" cellpadding="0" cellspacing="0">
                  <tr>
                    <td class="STYLE1"><div align="center"><img src="${applicationScope.ROOT}/admin/company/images/083.gif" width="14" height="14" /></div></td>
                    <td class="STYLE1"><div align="center">删除</div></td>
                  </tr>
              </table>
              </td>
               -->
            </tr>
        </table></td>
        <td width="14"><img src="${applicationScope.ROOT}/admin/company/images/tab_07.gif" width="14" height="30" /></td>
      </tr>
    </table></td>
  </tr>
  <tr>
    <td>
    <table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td width="9" background="${applicationScope.ROOT}/admin/company/images/tab_12.gif">&nbsp;</td>
        <td bgcolor="#f3ffe3" style="padding-bottom: 5px; padding-top: 5px;">
        <table width="99%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#c0de98">
        <tr>
        <td height="24" bgcolor="#FFFFFF" align="right"" style="padding-right: 10px;" class="STYLE2 STYLE1">
        <input id="positionInput" type="hidden" value="${requestScope.position.id}" />
        <span>品牌:&nbsp;</span>
        <select id="brandSelect" name="" style="width: 120px; border: 1px solid #666; font-size: 12px;"><option value="">--</option></select>&nbsp;&nbsp;&nbsp;
        <!-- 
        <span>公司:&nbsp;</span>
        <select id="companySelect" name="" style="width: 120px; border: 1px solid #666; font-size: 12px">
        <option value="">--</option>
        </select>&nbsp;&nbsp;&nbsp;
        <span>门店:&nbsp;</span>
        <select id="marketSelect" name="" style="width: 120px; border: 1px solid #666; font-size: 12px">
        <option value="">--</option>
        </select>&nbsp;&nbsp;&nbsp;
         -->
        <input type="button" value="查询" onclick="findList(1)" style="width:60px; height:22px; line-height:22px; font-size: 12px; cursor: pointer; text-align: center;" />
        </td>
        </tr>
        </table>
        </td>
        <td width="9" background="${applicationScope.ROOT}/admin/company/images/tab_16.gif">&nbsp;</td>
      </tr>
    </table>
    </td>
  </tr>
  <tr>
    <td>
    <table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td width="9" background="${applicationScope.ROOT}/admin/company/images/tab_12.gif">&nbsp;</td>
        <td id="listInfoTd" bgcolor="#f3ffe3">
        </td>
        <td width="9" background="${applicationScope.ROOT}/admin/company/images/tab_16.gif">&nbsp;</td>
      </tr>
    </table>
    </td>
  </tr>
  <tr>
    <td height="29"><table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td width="15" height="29"><img src="${applicationScope.ROOT}/admin/company/images/tab_20.gif" width="15" height="29" /></td>
        <td id="pageTd" background="${applicationScope.ROOT}/admin/company/images/tab_21.gif">
        </td>
        <td width="14"><img src="${applicationScope.ROOT}/admin/company/images/tab_22.gif" width="14" height="29" /></td>
      </tr>
    </table></td>
  </tr>
</table>

<div id="addDiv" class="white_content">
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td height="30"><table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td width="15" height="30"><img src="${applicationScope.ROOT}/admin/company/images/tab_03.gif" width="15" height="30" /></td>
        <td width="1101" background="${applicationScope.ROOT}/admin/company/images/tab_05.gif"><img src="${applicationScope.ROOT}/admin/company/images/311.gif" width="16" height="16" /> <span class="STYLE4">业务员管理 - 添加业务员</span></td>
        <td width="281" background="${applicationScope.ROOT}/admin/company/images/tab_05.gif" align="right" style="cursor: pointer;" onclick="closeAdd()">关闭</td>
        <td width="14"><img src="${applicationScope.ROOT}/admin/company/images/tab_07.gif" width="14" height="30" /></td>
      </tr>
    </table></td>
  </tr>
  <tr>
  	<td>
  	<form id="addForm" action="${applicationScope.ROOT}/admin/activity-admin!add" method="post">
    <table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td width="9" background="${applicationScope.ROOT}/admin/company/images/tab_12.gif">&nbsp;</td>
        <td bgcolor="#f3ffe3">
        <table width="100%" border="0" cellspacing="0" cellpadding="0">
	    <tr>
	    <td width="40%" height="40px;" align="right">主题：</td>
	    <td align="left"> <input id="subject_add" name="activity.subject" value="" /></td>
	    </tr>
	    <tr>
	    <td width="40%" height="40px;" align="right">内容：</td>
	    <td align="left"> <input id="content_add" name="activity.content" value="" /> </td>
	    </tr>
	    <tr>
	    <td width="40%" height="40px;" align="right">品牌：</td>
	    <td align="left"> 
		<select id="brandSelect_add" name="brand.id" style="width: 120px; border: 1px solid #666; font-size: 12px"></select>
		</td>
	    </tr>
	    <tr>
	    <td width="40%" height="40px;" align="right">开始时间：</td>
	    <td align="left">
	    <input id="startDate_add" name="activity.startDate" value="" onclick="WdatePicker({minDate:'%y-%M-{%d}'})" />
	    </td>
	    </tr>
	    <tr>
	    <td width="40%" height="40px;" align="right">结束时间：</td>
	    <td align="left">
	    <input id="endDate_add" name="activity.endDate" value="" onclick="WdatePicker({minDate:'#F{$dp.$D(\'startDate_add\')}'})" />
	    </td>
	    </tr>
	    <tr>
	    <td width="40%" height="40px;" align="right"></td>
	    <td align="left"><input type="button" value="确认" onclick="add()" /></td>
	    </tr>
	    </table>
        </td>
        <td width="9" background="${applicationScope.ROOT}/admin/company/images/tab_16.gif">&nbsp;</td>
      </tr>
    </table>
    </form>
    </td>
  </tr>
  <tr>
    <td height="29"><table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td width="15" height="29"><img src="${applicationScope.ROOT}/admin/company/images/tab_20.gif" width="15" height="29" /></td>
        <td background="${applicationScope.ROOT}/admin/company/images/tab_21.gif">
        <table width="100%"><tr><td></td></tr></table>
        </td>
        <td width="14"><img src="${applicationScope.ROOT}/admin/company/images/tab_22.gif" width="14" height="29" /></td>
      </tr>
    </table></td>
  </tr>
</table>
</div>
<div id="updateDiv" class="white_content">
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td height="30"><table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td width="15" height="30"><img src="${applicationScope.ROOT}/admin/company/images/tab_03.gif" width="15" height="30" /></td>
        <td width="1101" background="${applicationScope.ROOT}/admin/company/images/tab_05.gif"><img src="${applicationScope.ROOT}/admin/company/images/311.gif" width="16" height="16" /> <span class="STYLE4"><a href="${applicationScope.ROOT}/admin/company/companyInfo.jsp">系统管理 - 修改系统</a></span></td>
        <td width="281" background="${applicationScope.ROOT}/admin/company/images/tab_05.gif" align="right" style="cursor: pointer;" onclick="closeUpdate()">关闭</td>
        <td width="14"><img src="${applicationScope.ROOT}/admin/company/images/tab_07.gif" width="14" height="30" /></td>
      </tr>
    </table></td>
  </tr>
  <tr>
  	<td>
  	<form id="updateForm" action="${applicationScope.ROOT}/admin/product!updateProduct" method="post">
    <table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td width="9" background="${applicationScope.ROOT}/admin/company/images/tab_12.gif">&nbsp;</td>
        <td bgcolor="#f3ffe3">
        <input id="activityId_u" type="hidden" value="" />
        <table width="100%" border="0" cellspacing="0" cellpadding="0">
	    <tr>
	    <td width="40%" height="40px;" align="right">主题：</td>
	    <td align="left"> <input id="subject_u" name="activity.subject" value="" /></td>
	    </tr>
	    <tr>
	    <td width="40%" height="40px;" align="right">内容：</td>
	    <td align="left"> <input id="content_u" name="activity.content" value="" /> </td>
	    </tr>
	    <tr>
	    <td width="40%" height="40px;" align="right">品牌：</td>
	    <td align="left"> 
		<select id="brandSelect_u" name="brand.id" style="width: 120px; border: 1px solid #666; font-size: 12px"></select>
		</td>
	    </tr>
	    <tr>
	    <td width="40%" height="40px;" align="right">开始时间：</td>
	    <td align="left">
	    <input id="startDate_u" name="activity.startDate" value="" onclick="WdatePicker()" />
	    </td>
	    </tr>
	    <tr>
	    <td width="40%" height="40px;" align="right">结束时间：</td>
	    <td align="left">
	    <input id="endDate_u" name="activity.endDate" value="" onclick="WdatePicker({minDate:'#F{$dp.$D(\'startDate_u\')}'})" />
	    </td>
	    </tr>
	    <tr>
	    <td width="40%" height="40px;" align="right"></td>
	    <td align="left"><input id="updateButton" type="button" value="确认" /></td>
	    </tr>
	    </table>
        </td>
        <td width="9" background="${applicationScope.ROOT}/admin/company/images/tab_16.gif">&nbsp;</td>
      </tr>
    </table>
    </form>
    </td>
  </tr>
  <tr>
    <td height="29"><table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td width="15" height="29"><img src="${applicationScope.ROOT}/admin/company/images/tab_20.gif" width="15" height="29" /></td>
        <td background="${applicationScope.ROOT}/admin/company/images/tab_21.gif">
        <table width="100%"><tr><td></td></tr></table>
        </td>
        <td width="14"><img src="${applicationScope.ROOT}/admin/company/images/tab_22.gif" width="14" height="29" /></td>
      </tr>
    </table></td>
  </tr>
</table>
</div>
<div id="backGroud" class="black_overlay"></div>
</body>
</html>
